﻿using System.Net;
using System.Xml.Serialization;

namespace Toybox.NicoSharp.Video
{
	using Extensions;
	using Utilities;

	[XmlRoot("nicovideo_thumb_response")]
	public partial class ThumbInfo : NicoSharp.Abstracts.AbstractStatus
	{

		#region [Static]

		public static ThumbInfo Get(string completeId, CookieCollection cookies = null)
		{
			string url = NicoUrls.FlApi + "getthumbinfo/" + completeId;
			string xml = NicoWebClient.Get(url, cookies.Coerce());
			return Deserializer.XmlDeserializer<ThumbInfo>(xml);
		}

		#endregion [Static]


		#region Public Members

		/// <summary>
		/// 動画情報
		/// </summary>
		public Thumb thumb;

		#endregion Public Members

	}
}
